function getBeforeOneWeek() {
	const end = new Date();
	const start = new Date();
	end.setTime(end.getTime() + 3600 * 1000 * 24 * 7);
	return [start,end]
}
function getOneWeek() {
	const end = new Date();
	const start = new Date();
	start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
	return [start, end]
}

function getOneMonth() {
	const end = new Date();
	const start = new Date();
	start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
	return [start, end]
}

function getThreeMonth() {
	const end = new Date();
	const start = new Date();
	start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
	return [start, end]
}
function getSixMonth() {
	const end = new Date();
	const start = new Date();
	start.setTime(start.getTime() - 3600 * 1000 * 24 * 180);
	return [start, end]
}
function getTwelveMonth() {
	const end = new Date();
	const start = new Date();
	start.setTime(start.getTime() - 3600 * 1000 * 24 * 360);
	return [start, end]
}
export default {
	getBeforeOneWeek,
	getOneWeek,
	getOneMonth,
	getThreeMonth,
	getSixMonth,
	getTwelveMonth,
	// disabledDate(time) {
	// 	return time.getTime() > Date.now();
	// },
	shortcuts: [{
		text: '往后一周',
		onClick(picker) {
			picker.$emit('pick', getBeforeOneWeek());
		}
	},{
		text: '最近一周',
		onClick(picker) {
			picker.$emit('pick', getOneWeek());
		}
	}, {
		text: '最近一月',
		onClick(picker) {
			picker.$emit('pick', getOneMonth());
		}
	}, {
		text: '最近三月',
		onClick(picker) {
			picker.$emit('pick', getThreeMonth());
		}
	}, {
		text: '最近半年',
		onClick(picker) {
			picker.$emit('pick', getSixMonth());
		}
	}, {
		text: '最近一年',
		onClick(picker) {
			picker.$emit('pick', getTwelveMonth());
		}
	}]
}